package com.myccb.app.view.investment;


import android.content.Context;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Paint;
import android.support.annotation.Nullable;
import android.util.AttributeSet;
import android.view.View;

/**
 * Created by freak on 17-12-5.
 */

public class DrawSomething extends View {
    Paint paint = new Paint();

    public DrawSomething(Context context) {
        super(context);
    }

    public DrawSomething(Context context, @Nullable AttributeSet attrs) {
        super(context, attrs);
    }

    @Override
    protected void onDraw(Canvas canvas) {
        super.onDraw(canvas);
        canvas.translate(getWidth()/2, getHeight()/2);
        paint.setColor(Color.WHITE);
        paint.setStyle(Paint.Style.FILL);
        float j = 2;
        for (int i = 0; i < 270; i += 30){
            canvas.drawCircle(0, 80, j, paint);
            canvas.rotate(30);
            j += 0.6;
        }

    }
}
